﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using EbayQueryExpertLib.EbayFinding;

namespace EbayQueryExpertLib.Entities
{
    public abstract class AbstractSearchQuery
    {
        protected abstract void LoadFromURL(string url);


        private string m_Keywords;
        private List<string> m_Categories = new List<string>();
        private Dictionary<ItemFilterType, string> m_Filters = new Dictionary<ItemFilterType, string>();

        public Dictionary<ItemFilterType, string> Filters
        {
            get { return m_Filters; }
        }

        public AbstractSearchQuery(string url)
        {
            LoadFromURL(url);
        }
        public AbstractSearchQuery()
        {
        }

        public string Keywords
        {
            get { return m_Keywords; }
            set { m_Keywords = value; }
        }

        public List<string> Categories
        {
            get { return m_Categories; }
        }

        public string[] CategoriesArray
        {
            get
            {
                return m_Categories.ToArray();
            }
        }
    }
}
